Draft
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
added 26 commits
March 20, 2026 15:35
…k_modification_row_expansion
…k_modification_row_expansion
…k_modification_row_expansion
… dnd which messes up drag and drop id management
…k_modification_row_expansion
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.




PR Summary
Implements ability to insert and browse through composite modifications
What's included in this PR :
Technical notes :
Sub-modifications are lazily loaded: at initialisation only root-level modifications are retrieved. The backend metadata model does not include sub-modification content, so data reconciliation is performed client-side. When a composite is expanded, an API call retrieves its children and inserts them into the dataset. The new getNetworkModificationsFromComposite API accepts multiple UUIDs in a single call and returns a Record<UUID, NetworkModificationMetadata[]>, replacing the previous per-UUID request pattern.
This adds complexity around stale data management when the root dataset is updated via WebSocket notifications, but keeps the backend model simple and ensures faster initialisation. A suite of recursive tree utility functions (findModificationsInTree, updateModificationInTree, mergeSubModificationsIntoTree, moveSubModificationInTree, updateModificationFieldInTree) has been added to handle all tree traversal, optimistic update, and merge operations. When refetching sub-modifications after a data refresh, previously loaded nested children are preserved by merging the fresh API response with the existing tree state.
The DnD logic has been split into two distinct paths since root-level moves and composite sub-modification moves have different backend models: root moves operate on group UUIDs, while composite moves reference parent composite UUIDs via a dedicated endpoint (PUT .../composite-sub-modification/{modificationUuid}).
What's left to do :
Additional note :
Sonar reliability rating is a false positive triggered by yup schema structure